Insert strings into array/buffer/list?

Hi all,

i have 3 strings for example

string a = "a"

string b = "b"

string c = "c"

and i want to put/write/insert them into a array/list/buffer

but with "put()" i can insert only 1...And i don't want to write put(a)..put(b)...put(c)...put(x) and so on

My first idea was to write them into in a own created group...

for do that -> for myStrings in myStringGroup do.. // something like that

But i have no idea how to crate a own group :(

I would be happy if you can help me

 


meinhana - Wed Sep 02 04:45:50 EDT 2015

Re: Insert strings into array/buffer/list?
meinhana - Wed Sep 02 07:22:17 EDT 2015

I found this, but how can i get the strings back?

string a = "a"
string b = "b"
string c = "c"

Skip sk = create
string sl[] = {a, b, c} 

int i 

for (i=0; i<sizeof(sl); i++)
{
        put(sk, sl[i], sl[i])
        print "I: " i "\n"  
}  

for i in sk do
{
        print i;        
}

 

Re: Insert strings into array/buffer/list?
Mike.Scharnow - Wed Sep 02 07:42:43 EDT 2015

meinhana - Wed Sep 02 07:22:17 EDT 2015

I found this, but how can i get the strings back?

string a = "a"
string b = "b"
string c = "c"

Skip sk = create
string sl[] = {a, b, c} 

int i 

for (i=0; i<sizeof(sl); i++)
{
        put(sk, sl[i], sl[i])
        print "I: " i "\n"  
}  

for i in sk do
{
        print i;        
}

 

the last part should be

string s
for s in sk do 
{
        print s "\n"
}

 

Re: Insert strings into array/buffer/list?
meinhana - Wed Sep 02 07:46:07 EDT 2015

Mike.Scharnow - Wed Sep 02 07:42:43 EDT 2015

the last part should be

string s
for s in sk do 
{
        print s "\n"
}

 

Oh my God, Thank you :) I was so blind Shy